import { postRequest, getRequest } from '/src/lib/axios';
export const greenCertificate = {
  query: (param) => {
    return postRequest('/greenCertificateProjects/queryPage', {
      ...param,
      searchCount: true,
      sortItemList: [
        {
          isAsc: true,
          column: 'certificate_project_id',
        },
      ],
    });
  },
  Add: (param) => {
    return postRequest('/greenCertificateProjects/add', param);
  },
  Update: (param) => {
    return postRequest('/greenCertificateProjects/update', param);
  },
  Delete: (param) => {
    return getRequest(`/greenCertificateProjects/delete/${param}`);
  },
  queryAssetsCategory: (param) => {
    return postRequest('/carbonAssetsCategory/queryPage', {
      ...param,
      searchCount: true,
      sortItemList: [
        {
          isAsc: true,
          column: 'ca_category_id',
        },
      ],
    });
  },
};
